package site.thatime.hyts.web.controller;

import javax.annotation.Resource;

import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

import site.thatime.hyts.model.PdaUser;
import site.thatime.hyts.model.Result;
import site.thatime.hyts.service.PdaUserService;

@RestController
@RequestMapping("/user")
public class UserController {
	@Resource
	private PdaUserService pdaUserService;

	@RequestMapping(path = "/login/{id}", method = RequestMethod.POST)
	public PdaUser login(@PathVariable("id") String id) {
		return null;
	}

	@RequestMapping(path = "/download", method = RequestMethod.GET)
	public Result download() {
		return new Result(true).setData(pdaUserService.getAll());
	}
}
